Integrand size = 19, antiderivative size = 74 \[ \int \frac {1}{a \sin (c+d x)+b \tan (c+d x)} \, dx=\frac {\log (1-\cos (c+d x))}{2 (a+b) d}-\frac {\log (1+\cos (c+d x))}{2 (a-b) d}+\frac {b \log (b+a \cos (c+d x))}{\left (a^2-b^2\right ) d} \]
[Out]
Time = 0.10 (sec) , antiderivative size = 74, normalized size of antiderivative = 1.00, number of steps used = 4, number of rules used = 3, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.158, Rules used = {4482, 2800, 815} \[ \int \frac {1}{a \sin (c+d x)+b \tan (c+d x)} \, dx=\frac {b \log (a \cos (c+d x)+b)}{d \left (a^2-b^2\right )}+\frac {\log (1-\cos (c+d x))}{2 d (a+b)}-\frac {\log (\cos (c+d x)+1)}{2 d (a-b)} \]
[In]
[Out]
Rule 815
Rule 2800
Rule 4482
Rubi steps \begin{align*} \text {integral}& = \int \frac {\cot (c+d x)}{b+a \cos (c+d x)} \, dx \\ & = -\frac {\text {Subst}\left (\int \frac {x}{(b+x) \left (a^2-x^2\right )} \, dx,x,a \cos (c+d x)\right )}{d} \\ & = -\frac {\text {Subst}\left (\int \left (\frac {1}{2 (a+b) (a-x)}+\frac {1}{2 (a-b) (a+x)}+\frac {b}{(-a+b) (a+b) (b+x)}\right ) \, dx,x,a \cos (c+d x)\right )}{d} \\ & = \frac {\log (1-\cos (c+d x))}{2 (a+b) d}-\frac {\log (1+\cos (c+d x))}{2 (a-b) d}+\frac {b \log (b+a \cos (c+d x))}{\left (a^2-b^2\right ) d} \\ \end{align*}
Time = 0.08 (sec) , antiderivative size = 63, normalized size of antiderivative = 0.85 \[ \int \frac {1}{a \sin (c+d x)+b \tan (c+d x)} \, dx=\frac {-\left ((a+b) \log \left (\cos \left (\frac {1}{2} (c+d x)\right )\right )\right )+b \log (b+a \cos (c+d x))+(a-b) \log \left (\sin \left (\frac {1}{2} (c+d x)\right )\right )}{(a-b) (a+b) d} \]
[In]
[Out]
Time = 0.46 (sec) , antiderivative size = 70, normalized size of antiderivative = 0.95
method | result | size |
derivativedivides | \(\frac {\frac {\ln \left (\cos \left (d x +c \right )-1\right )}{2 a +2 b}+\frac {b \ln \left (b +\cos \left (d x +c \right ) a \right )}{\left (a +b \right ) \left (a -b \right )}-\frac {\ln \left (\cos \left (d x +c \right )+1\right )}{2 a -2 b}}{d}\) | \(70\) |
default | \(\frac {\frac {\ln \left (\cos \left (d x +c \right )-1\right )}{2 a +2 b}+\frac {b \ln \left (b +\cos \left (d x +c \right ) a \right )}{\left (a +b \right ) \left (a -b \right )}-\frac {\ln \left (\cos \left (d x +c \right )+1\right )}{2 a -2 b}}{d}\) | \(70\) |
risch | \(\frac {i x}{a -b}+\frac {i c}{d \left (a -b \right )}-\frac {i x}{a +b}-\frac {i c}{d \left (a +b \right )}-\frac {2 i b x}{a^{2}-b^{2}}-\frac {2 i b c}{\left (a^{2}-b^{2}\right ) d}-\frac {\ln \left ({\mathrm e}^{i \left (d x +c \right )}+1\right )}{d \left (a -b \right )}+\frac {\ln \left ({\mathrm e}^{i \left (d x +c \right )}-1\right )}{d \left (a +b \right )}+\frac {b \ln \left ({\mathrm e}^{2 i \left (d x +c \right )}+\frac {2 b \,{\mathrm e}^{i \left (d x +c \right )}}{a}+1\right )}{\left (a^{2}-b^{2}\right ) d}\) | \(171\) |
[In]
[Out]
none
Time = 0.29 (sec) , antiderivative size = 64, normalized size of antiderivative = 0.86 \[ \int \frac {1}{a \sin (c+d x)+b \tan (c+d x)} \, dx=\frac {2 \, b \log \left (a \cos \left (d x + c\right ) + b\right ) - {\left (a + b\right )} \log \left (\frac {1}{2} \, \cos \left (d x + c\right ) + \frac {1}{2}\right ) + {\left (a - b\right )} \log \left (-\frac {1}{2} \, \cos \left (d x + c\right ) + \frac {1}{2}\right )}{2 \, {\left (a^{2} - b^{2}\right )} d} \]
[In]
[Out]
\[ \int \frac {1}{a \sin (c+d x)+b \tan (c+d x)} \, dx=\int \frac {1}{a \sin {\left (c + d x \right )} + b \tan {\left (c + d x \right )}}\, dx \]
[In]
[Out]
none
Time = 0.21 (sec) , antiderivative size = 71, normalized size of antiderivative = 0.96 \[ \int \frac {1}{a \sin (c+d x)+b \tan (c+d x)} \, dx=\frac {\frac {b \log \left (a + b - \frac {{\left (a - b\right )} \sin \left (d x + c\right )^{2}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{2}}\right )}{a^{2} - b^{2}} + \frac {\log \left (\frac {\sin \left (d x + c\right )}{\cos \left (d x + c\right ) + 1}\right )}{a + b}}{d} \]
[In]
[Out]
none
Time = 0.30 (sec) , antiderivative size = 100, normalized size of antiderivative = 1.35 \[ \int \frac {1}{a \sin (c+d x)+b \tan (c+d x)} \, dx=\frac {\frac {2 \, b \log \left ({\left | -a - b - \frac {a {\left (\cos \left (d x + c\right ) - 1\right )}}{\cos \left (d x + c\right ) + 1} + \frac {b {\left (\cos \left (d x + c\right ) - 1\right )}}{\cos \left (d x + c\right ) + 1} \right |}\right )}{a^{2} - b^{2}} + \frac {\log \left (\frac {{\left | -\cos \left (d x + c\right ) + 1 \right |}}{{\left | \cos \left (d x + c\right ) + 1 \right |}}\right )}{a + b}}{2 \, d} \]
[In]
[Out]
Time = 22.62 (sec) , antiderivative size = 67, normalized size of antiderivative = 0.91 \[ \int \frac {1}{a \sin (c+d x)+b \tan (c+d x)} \, dx=\frac {\ln \left (\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )\right )}{d\,\left (a+b\right )}+\frac {b\,\ln \left (a+b-a\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^2+b\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^2\right )}{d\,\left (a^2-b^2\right )} \]
[In]
[Out]